﻿package mortal.game.net.command.copy.groupCopy
{
    import Framework.MQ.*;
    import Message.Command.*;
    import Message.Public.*;
    import mortal.game.cache.*;
    import mortal.game.mvc.*;
    import mortal.game.net.broadCast.*;
    import mortal.game.view.copy.*;
    import mortal.mvc.core.*;

    public class CopyFirstBloodCommand extends BroadCastCall
    {

        public function CopyFirstBloodCommand(param1:Object)
        {
            super(param1);
            return;
        }// end function

        override public function call(param1:MessageBlock) : void
        {
            var _loc_3:SCopyFirstBloodInfo = null;
            var _loc_2:* = Cache.instance.copy;
            switch(param1.messageHead.command)
            {
                case EPublicCommand._ECmdPublicCopyFirstBloodReward:
                {
                    _loc_2.copyFirstBloodDic = (param1.messageBase as SCopyFirstBloodInfosMsg).infos;
                    NetDispatcher.dispatchCmd(ServerCommand.CopyFirstBloodRewardUpdate, _loc_3);
                    break;
                }
                case EPublicCommand._ECmdPublicCopyFirstBloodRewardUpdate:
                {
                    _loc_3 = param1.messageBase as SCopyFirstBloodInfo;
                    _loc_2.copyFirstBloodDic[_loc_3.copyCode] = _loc_3.type;
                    NetDispatcher.dispatchCmd(ServerCommand.CopyFirstBloodRewardUpdate, _loc_3);
                    break;
                }
                default:
                {
                    break;
                }
            }
            return;
        }// end function

    }
}
